using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace HeresyManager.Traits
{
    [Serializable]
    public class UnnaturalCharacteristic : Trait
    {
        public Charackteristic? Charackteristic { get; private set; }

        private Trait t;

        public UnnaturalCharacteristic()
        {
        }

        public UnnaturalCharacteristic(Charackteristic c)
            : this()
        {
            this.Charackteristic = c;
        }

        public override string Name
        {
            get { return "Unnatural " + Charackteristic == null ? "Characteristic" : Charackteristic.ToString(); }
        }

        public override IEnumerator<Comunication.Comunicator> Accire(Character c)
        {
            var enu = base.Accire(c);
            while (enu.MoveNext())
                yield return enu.Current;
            var com = new Comunication.ChooseOne<Charackteristic>("Choose Characteristic", new Charackteristic[] { });
            while (com.SelectedValue == null)
                yield return com;

        }

    }
}
